<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>路由规则的嵌套</title>
		<script src="../js/vue.js"></script>
		<script src="../js/vue-router.js"></script>
	</head>
	<body>
		<div id="app">
			<h1>宠物</h1>
			<router-link to="/dog">小狗</router-link>
			<router-link to="/cat">小猫</router-link>
			<router-view></router-view>
		</div>
		<template id="Dtem">
			<div>
				<h3></h3>
			</div>
		</template>
		<template id="Ctem">
			<div>
				<h3></h3>
			</div>
		</template>
		<script>
		const DTem = {
			template:"#Dtem"
		}
		const CTem = {
			template:"#Ctem"
		}
		const router = new VueRouter({
			routes:[
				{path:"/dog",component:DTem},
				{path:"/cat",component:CTem,
				children:[
					{path:"",component:},
					{path:"",component:}
				]}
			]
		})
		const app = new Vue({
			el:"#app",
			router:router
		})
		</script>
	</body>
</html>
